<template>
  <div class="house-change-main">
    <div class="right">
      <div class="header">房屋性质变更</div>
      <div class="verify">待核实{{verify}}件</div>
      <div class="last">
        <span class="month">环比上月:</span>
        <span class="number">{{number}}</span>
      </div>
    </div>
    <div ref="box" style="height:200px;width:50%;">

    </div>
  </div>
</template>

<script>
import echarts from "echarts"
export default {
  data() {
    return {
      verify: 10,
      number: 20 + "%"
    }
  },
  methods: {
    print() {
      let print = echarts.init(this.$refs.box)
      let option = {
        title: [
          {
            // text: '房屋性质改变',
            textStyle: {
              color: "yellow"
            }
          }
        ],
        xAxis: {
          type: "category",
          data: ["Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"]
        },
        yAxis: {
          type: "value"
        },
        series: [{
          data: [120, 200, 150, 80, 70, 110, 130],
          type: "bar"
        }]
      }
      print.setOption(option)
    }
  },
  mounted() {
    this.print()
  }
}
</script>

<style lang="scss">
  .house-change-main {
    display: flex;
    .right {
      width: 50%;
      display: flex;
      flex-direction: column;
      .header {
        color: yellow;
        // flex:2;
        box-sizing: border-box;
        padding: 10px;
      }
      .verify {
        color:white;
        // text-align: center;
        box-sizing: border-box;
        padding-top: 30px;
        padding-left: 30px;
        // flex:1
      }
      .last {
        color: white;
        // text-align: center;
        box-sizing: border-box;
        padding: 30px;
        // flex:1;
        .month {
          color: #D3D3D3
        }
        .number {
          color: red;
        }
      }
    }
  }
</style>